app.service("blogTypeService",function($http){
	this.findTypeList = function(page,rows){
		return $http.get("./blogType/getBlogTypeList.do?page="+page+"&rows="+rows);
	}
	
	this.findBlogTypeByTypeId = function(typeId){
		return $http.get("./blogType/getBlogTypeByTypeId.do?typeId="+typeId);
	}
	
	//保存分类
	this.save = function(methodName,entity){
		return $http.post("./blogType/"+methodName+".do",entity);
	}
	
	this.getBlogTypeById = function(id){
		return $http.get("./blogType/getBlogTypeById.do?typeId="+id);
	}
	
	//删除
	this.del = function(ids){
		return $http.get("./blogType/delete.do?ids="+ids);
	}
	
	this.search = function(page,rows,searchEntity){
		return $http.post("./blogType/search.do?page="+page+"&rows="+rows,searchEntity);
	}
	
	this.findAll = function(){
		return $http.get("./blogType/findAll.do");
	}
	
});